﻿@using BootstrapBlazor.Components
@using TrackSystem.Entities.Dtos.Sensor

<p>描 述:  @(sensor.Description ??= "无描述")</p>
<p>站地址: @sensor.Station</p>

<Divider class="mt-3 mb-3" />

@if (sensor.RO_Length == 0)
{
    <p>只读寄存器: 无</p>
}
else
{
    <p>只读寄存器: @sensor.RO_Address - @(sensor.RO_Address + sensor.RO_Length - 1)</p>
}

@if (sensor.RW_Length == 0)
{
    <p>读写寄存器: 无</p>
}
else
{
    <p>读写寄存器: @sensor.RW_Address - @(sensor.RW_Address + sensor.RW_Length - 1)</p>
}


@code{
    [Parameter]
    public SensorDto sensor { get; set; }

}
